var http = require('http');
var fs = require('fs');

var hostname='127.0.0.1';
var port='3000';

var server=http.createServer(function(req,res){
    fs.readFile('./1.html',function(err,data){
        if (err) {res.end('报错');return;};
        res.end(data);
    });
});

server.listen(port,hostname);